#ifndef VSTYLE_H
#define VSTYLE_H

class VStyle: public QObject
{
	Q_OBJECT
	Q_PROPERTY(QString family READ family WRITE setFamily)
	Q_PROPERTY(int pointSize READ pointSize WRITE setPointSize)
	Q_PROPERTY(bool bold READ bold WRITE setBold)
	Q_PROPERTY(bool italic READ italic WRITE setItalic)
	Q_PROPERTY(bool underline READ underline WRITE setUnderline)
	Q_PROPERTY(QColor color READ color WRITE setColor)
	Q_PROPERTY(QColor bgColor READ bgColor WRITE setBgColor)

public:
	VStyle(QObject* parent=0);

public:
	virtual QString serialize() const;

public:
	QString family() const;
	void setFamily(const QString& family);

	int pointSize() const;
	void setPointSize(int pointSize);

	bool bold() const;
	void setBold(bool enable);

	bool italic() const;
	void setItalic(bool enable);

	bool underline() const;
	void setUnderline(bool enable);

	QColor color() const;
	void setColor(const QColor& color);

	QColor bgColor() const;
	void setBgColor(const QColor& bgColor);

	QFont font() const;
	void setFont(const QFont& font);

	void show();

private:
	QFont m_font;
	QColor m_color;
	QColor m_bgColor;
	QString m_name;
};
//QML_DECLARE_TYPE(VStyle);

#endif // VSTYLE_H
